@extends('.app.layout')

@section('title','政策详情')
@section('head')
    <link href="/code/css/main.css" rel="stylesheet" />
@endsection
@section('content')
    <header class="mui-bar mui-bar-nav">
        <span href="###" class="mui-pull-left return" onclick="aOfApp('{{route('app.post-list',['slug'=>'rczc'])}}')">
            <img src="/code/images/back.png" />
        </span>
        <h1 class="mui-title">政策详情</h1>
        <span  class="mui-pull-right shareBtn" onclick="share('{{route('app.post-index',['id'=>$post->id])}}','{{$post->post_title}}','{{asset('storage/'.$post->thumb)}}','{{$post->digest}}')">
            <img src="/code/images/share.png" />
        </span>
    </header>
    <div class="mui-content">
        <div class="detail">
            <div class="detail-title">{{$post->post_title}}</div>
            <div class="detail-time">{{$post->created_at->format('m/d H:i')}}</div>
            <!-- <div class="detail-img"><img src="{{asset('storage/'.$post->thumb)}}"></div> -->
            <div class="detail-content">
                {!! $post->content !!}
            </div>
        </div>
        @if($post->file&&$post->file[1]['savepath'])

                <div class="mui-bar mui-load">
                    <span onclick="downloads('{{asset('storage/'.$post->file[1]['savepath'])}}')">
                        <span class="load-icon"></span>
                        <span class="load-text">下载文件</span>
                    </span>
                </div>
        @endif
    </div>
@endsection